import request from '../utils/request2'

export function getTem(params){
  return request({
    url:'/templates',
    method:'get',
    params
  })
}

export function deleteTem(id){
  return request({
    url:'/templates/' + id,
    method:'delete'
  })
}

export function changeTem(data){
  return request({
    url:'/templates/' + data.id,
    method:'put',
    data
  })
}

export function addTem(data){
  return request({
    url:'/templates',
    method:'post',
    data
  })
}